package com.sq.partner.manager.dao.impl;

import java.util.List;

import org.springframework.stereotype.Repository;

import com.sq.partner.manager.dao.SalesareaDao;
import com.sq.partner.manager.mybatis.model.Salesarea;

@Repository
public class SalesareaDaoImpl extends BaseDaoImpl implements SalesareaDao{
	@Override
	public boolean insert(List<Salesarea> sale) throws Exception{
		return this.add("insertSalesarea", sale);
	}
	@Override
	public boolean delete(Salesarea sale) throws Exception{
		return this.delete("deleteSalesarea",sale);
	}
	@Override
	public boolean update(Salesarea sale) throws Exception{
		return this.update("updateSalesarea", sale);
	}
	@Override
	public Salesarea query(Salesarea sale) throws Exception{
		return (Salesarea)this.query("querySalesareaList", sale);
	}
	@SuppressWarnings("unchecked")
	@Override
	public List<Salesarea> queryList(Salesarea sale) throws Exception{
		return (List<Salesarea>)this.queryList("querySalesareaList",sale);
	}
	@Override
	public Integer queryCount(Salesarea sale) throws Exception{
		return (Integer)this.query("querySaleCount",sale);
	}
}
